package utils;

import flixel.FlxObject;


class Collision{
	public static function myoverlap(Obj1: FlxObject, Obj2: FlxObject): Bool
	{
		if(	((Obj1.x >= Obj2.x && Obj1.x <= Obj2.x + Obj2.width) &&
			(Obj1.y >= Obj2.y && Obj1.y <= Obj2.y + Obj2.height)) ||
			((Obj2.x >= Obj1.x && Obj2.x <= Obj1.x + Obj1.width) &&
			(Obj2.y >= Obj1.y && Obj2.y <= Obj1.y + Obj1.height)))
			return true;
		else return false;
	}
}